MigrationUtils
object MigrationUtils
Functions
Link copied to clipboard
Link copied to clipboard
fun generateMigrationScript(vararg tables: Table, scriptDirectory: String, scriptName: String, withLogs: Boolean = true): File
This function simply generates the migration script without applying the migration. Its purpose is to show what the migration script will look like before applying the migration. If a migration script with the same name already exists, its content will be overwritten.
Link copied to clipboard
fun statementsRequiredForDatabaseMigration(vararg tables: Table, withLogs: Boolean = true): List<String>
Returns the SQL statements that need to be executed to make the existing database schema compatible with the table objects defined using Exposed. Unlike statementsRequiredToActualizeScheme, DROP/DELETE statements are included.